<div class="query-builder">
	<form [formGroup]="searchForm" class="h" nz-form>

		<div class="flex w align-items-center h">
			<div class="col-1-5 col-1-5-md">
				<div class="flex">
					<button (click)="search()" class="mr10" nz-button nzType="primary">搜索</button>
					<button (click)="reset()" class="mr10" nz-button nzType="default">重置</button>
				</div>
			</div>
		</div>
		<div class="flex w align-items-center h mt-[10px]">
			<div class="col-1-5 col-1-5-md">
				<nz-form-item nzFlex>
					<nz-form-label>理货时间</nz-form-label>
					<nz-form-control class="flex1">
						<nz-range-picker class="w-full" [nzRanges]="dateRanges" nzFormat="yyyy-MM-dd"
														 formControlName="startAndEndTime"></nz-range-picker>
					</nz-form-control>
				</nz-form-item>
			</div>
			<div class="col-1-5 col-1-5-md">
				<nz-form-item nzFlex>
					<nz-form-label>班次</nz-form-label>
					<nz-form-control class="flex1">
						<nz-select formControlName="timeSpace" nzShowSearch nzAllowClear>
							<nz-option *ngFor="let item of timeSpaceList" [nzValue]="item!.dictKey"
												 [nzLabel]="item!.dictValue"></nz-option>
						</nz-select>
					</nz-form-control>
				</nz-form-item>
			</div>
			<div class="col-1-5 col-1-5-md">
				<nz-form-item nzFlex>
					<nz-form-label>船信息</nz-form-label>
					<nz-form-control class="flex1">
						<nz-select formControlName="transportShipId" nzShowSearch nzAllowClear (nzOnSearch)="searchShipList($event)"
											 (ngModelChange)="searchBillList($event)">
							<nz-option *ngFor="let item of shipList" [nzValue]="item!.transportShipId"
												 [nzLabel]="item!.shipInfo"></nz-option>
						</nz-select>
					</nz-form-control>
				</nz-form-item>
			</div>
			<div class="col-1-5 col-1-5-md">
				<nz-form-item nzFlex>
					<nz-form-label>单号</nz-form-label>
					<nz-form-control class="flex1">
						<nz-select formControlName="transportBillId" nzShowSearch nzAllowClear
											 (nzOnSearch)="searchShipList($event)">
							<nz-option *ngFor="let item of billList" [nzValue]="item!.transportBillId"
												 [nzLabel]="item!.billNo"></nz-option>
						</nz-select>
					</nz-form-control>
				</nz-form-item>
			</div>
			<div class="col-1-5 col-1-5-md">
				<nz-form-item nzFlex>
					<nz-form-label>理货员</nz-form-label>
					<nz-form-control class="flex1">
						<nz-select formControlName="createUser" nzShowSearch nzAllowClear>
							<nz-option *ngFor="let item of userList" [nzValue]="item?.id"
												 [nzLabel]="item?.name"></nz-option>
						</nz-select>
					</nz-form-control>
				</nz-form-item>
			</div>
		</div>
		<div class="flex w align-items-center h mt-[10px]">
			<div class="col-1-5 col-1-5-md">
				<nz-form-item nzFlex>
					<nz-form-label>区域</nz-form-label>
					<nz-form-control class="flex1">
						<nz-select formControlName="areaId" [nzShowSearch]="true" nzAllowClear>
							<nz-option *ngFor="let item of locationList" [nzLabel]="item?.name" [nzValue]="item?.id"></nz-option>
						</nz-select>
					</nz-form-control>
				</nz-form-item>
			</div>
			<div class="col-1-5 col-1-5-md">
				<nz-form-item nzFlex>
					<nz-form-label>作业过程</nz-form-label>
					<nz-form-control class="flex1">
						<nz-select formControlName="operationType" [nzShowSearch]="true" nzAllowClear>
							<nz-option *ngFor="let item of operationProcessList" [nzLabel]="item?.name" [nzValue]="item?.id"></nz-option>
						</nz-select>
					</nz-form-control>
				</nz-form-item>
			</div>
			<div class="col-1-5 col-1-5-md">
				<nz-form-item nzFlex>
					<nz-form-label>出入库</nz-form-label>
					<nz-form-control class="flex1">
						<nz-select formControlName="tallyType" nzShowSearch nzAllowClear>
							<nz-option *ngFor="let item of tallyTypeList" [nzValue]="item!.dictKey"
												 [nzLabel]="item!.dictValue"></nz-option>
						</nz-select>
					</nz-form-control>
				</nz-form-item>
			</div>
		</div>
	</form>
</div>
<nz-tabset nzSize="default">
	<nz-tab nzTitle="入库、出库、直接作业">
		<app-tally-manage-unlock-ost-list #ostList [searchParams]="searchParams"></app-tally-manage-unlock-ost-list>
	</nz-tab>
	<nz-tab nzTitle="杂作业、转配">
		<app-tally-manage-unlock-tst-list #tstList [searchParams]="searchParams"></app-tally-manage-unlock-tst-list>
	</nz-tab>
	<nz-tab nzTitle="散货外捣">
		<app-tally-manage-unlock-bulk-list #bulkList [searchParams]="searchParams"></app-tally-manage-unlock-bulk-list>
	</nz-tab>
</nz-tabset>
